import Vue from 'vue'
import App from './App.vue'

import 'normalize.css/normalize.css' // A modern alternative to CSS resets
import '@/styles/index.scss' // global css


//引入图状统计器
//import echarts from 'echarts' 报错
import * as echarts from 'echarts'//报错可以使用
Vue.prototype.$echarts=echarts

//引入mavonEditor文本编辑器
import mavonEditor from"mavon-editor"
import 'mavon-editor/dist/css/index.css'
Vue.use(mavonEditor);


//引入swiper轮播图
import VueAwesomeSwiper from 'vue-awesome-swiper'
import 'swiper/dist/css/swiper.css'
Vue.use(VueAwesomeSwiper)

// 引入element
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
Vue.use(ElementUI);


// 引入登陆的动态原点样式
import Particles from "vue-particles";
Vue.use(Particles);

// 分页组件
import Pagination from "@/components/Pagination"
Vue.component("Pagination", Pagination)

import VueQuillEditor from 'vue-quill-editor'
// require styles 导入富文本编辑器对应的样式
import 'quill/dist/quill.core.css'
import 'quill/dist/quill.snow.css'
import 'quill/dist/quill.bubble.css'
Vue.use(VueQuillEditor, /* { default global options } */ )

import XLSX from 'xlsx'
Vue.prototype.XLSX = XLSX



import VueDirectiveImagePreviewer from 'vue-directive-image-previewer'
import 'vue-directive-image-previewer/dist/assets/style.css'
Vue.use(VueDirectiveImagePreviewer, {
    zIndex: 9999, //层级显示
    previewSize: 3 //三倍图
})

import 'viewerjs/dist/viewer.css'
import Viewer from 'v-viewer'

Vue.use(Viewer, {
    defaultOptions: {
        zIndex: 9999
    }
})

// 挂载全局api
import api from './request/api'
Vue.prototype.$api = api

// 挂载本地缓存
import { Local } from '@/utils/storage'
Vue.prototype.$Local = Local

// 引入vuex
import store from './store'

// 引入路由
import router from './router'

import '@/permission' // permission control

Vue.config.productionTip = false

new Vue({
    render: h => h(App),
    // 挂载路由
    router,
    store,
}).$mount('#app')
